<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../../style.css" type="text/css" media="screen">
<link rel="stylesheet" href="../../print.css" type="text/css" media="print">
<meta content="Highlighter,flexlib.controls.Highlighter,field,highlightColor,xOffset,yOffset,bitmap,reset,highlightWordInstances,highlightNext,highlightPrevious" name="keywords">
<title>flexlib.controls.Highlighter</title>
</head>
<body>
<script type="text/javascript" language="javascript" src="../../asdoc.js"></script><script type="text/javascript" language="javascript" src="../../cookies.js"></script><script type="text/javascript" language="javascript">
<!--
				asdocTitle = 'Highlighter - flexlib';
				var baseRef = '../../';
				window.onload = configPage;
			--></script>
<table style="display:none" id="titleTable" cellspacing="0" cellpadding="0" class="titleTable">
<tr>
<td align="left" class="titleTableTitle">API Documentation</td><td align="right" class="titleTableTopNav"><a onclick="loadClassListFrame('../../all-classes.html')" href="../../package-summary.html">All&nbsp;Packages</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../all-classes.html')" href="../../class-summary.html">All&nbsp;Classes</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../index-list.html')" href="../../all-index-A.html">Index</a>&nbsp;|&nbsp;<a href="../../index.html?flexlib/controls/Highlighter.html&amp;flexlib/controls/class-list.html" id="framesLink1">Frames</a><a onclick="parent.location=document.location" href="" style="display:none" id="noFramesLink1">No&nbsp;Frames</a></td><td rowspan="3" align="right" class="titleTableLogo"><img alt="Adobe Logo" title="Adobe Logo" class="logoImage" src="../../images/logo.jpg"></td>
</tr>
<tr class="titleTableRow2">
<td align="left" id="subTitle" class="titleTableSubTitle">Class&nbsp;Highlighter</td><td align="right" id="subNav" class="titleTableSubNav"><a href="#propertySummary">Properties</a>&nbsp;| <a href="#methodSummary">Methods</a></td>
</tr>
<tr class="titleTableRow3">
<td colspan="2">&nbsp;</td>
</tr>
</table>
<script type="text/javascript" language="javascript">
<!--
if (!isEclipse() || window.name != ECLIPSE_FRAME_NAME) {titleBar_setSubTitle("Class Highlighter"); titleBar_setSubNav(false,true,false,false,false,false,true,false,false,false,false,false,false,false);}
--></script>
<div class="MainContent">
<table cellspacing="0" cellpadding="0" class="classHeaderTable">
<tr>
<td class="classHeaderTableLabel">Package</td><td><a onclick="javascript:loadClassListFrame('class-list.html')" href="package-detail.html">flexlib.controls</a></td>
</tr>
<tr>
<td class="classHeaderTableLabel">Class</td><td class="classSignature">public class Highlighter</td>
</tr>
</table>
<p></p>
<p></p>
<br>
<hr>
</div>
<a name="propertySummary"></a>
<div class="summarySection">
<div class="summaryTableTitle">Public Properties</div>
<table id="summaryTableProperty" class="summaryTable " cellpadding="3" cellspacing="0">
<tr>
<th>&nbsp;</th><th colspan="2">Property</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#bitmap">bitmap</a> : Bitmap<div class="summaryTableDescription">
        The Bitmap object used for drawing the highlights.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#field">field</a> : TextField<div class="summaryTableDescription">
     The TextField being highlighted.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#highlightColor">highlightColor</a> : uint<div class="summaryTableDescription">
        The color used to highlight strings (RGBA).</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#xOffset">xOffset</a> : Number<div class="summaryTableDescription">
        The horizontal offset for highlights.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#yOffset">yOffset</a> : Number<div class="summaryTableDescription">
        The vertical offset for highlights.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
</table>
</div>
<a name="methodSummary"></a>
<div class="summarySection">
<div class="summaryTableTitle">Public Methods</div>
<table id="summaryTableMethod" class="summaryTable " cellpadding="3" cellspacing="0">
<tr>
<th>&nbsp;</th><th colspan="2">Method</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#Highlighter()">Highlighter</a>(textField:TextField, color:uint = 0xffff0000, xOffset:Number = 0, yOffset:Number = 0)</div>
<div class="summaryTableDescription">
        Finds & highlights strings in a text field.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#highlightNext()">highlightNext</a>(word:String, caseSensitive:Boolean = true):void</div>
<div class="summaryTableDescription">
        Highlights the first instance of a string after the cursor position.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#highlightPrevious()">highlightPrevious</a>(word:String, caseSensitive:Boolean = true):void</div>
<div class="summaryTableDescription">
        Highlights the first instance of a string before the cursor position.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#highlightWordInstances()">highlightWordInstances</a>(word:String, caseSensitive:Boolean = true):void</div>
<div class="summaryTableDescription">
  Highlights all instances of a string.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#reset()">reset</a>():void</div>
<div class="summaryTableDescription">
        Resets the Highlighter, clearing all visible highlights and emptying the array of character boundaries.</div>
</td><td class="summaryTableOwnerCol">Highlighter</td>
</tr>
</table>
</div>
<script type="text/javascript" language="javascript">
<!--
showHideInherited();
--></script>
<div class="MainContent">
<a name="propertyDetail"></a>
<div class="detailSectionHeader">Property detail</div>
<a name="bitmap"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">bitmap</td><td class="detailHeaderType">property</td>
</tr>
</table>
<div class="detailBody">
<code>public var bitmap:Bitmap</code><p>
        The Bitmap object used for drawing the highlights.  Publicly exposed so that effects can be applied if desired.
        </p></div>
<a name="field"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">field</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public var field:TextField</code><p>
     The TextField being highlighted.
     </p></div>
<a name="highlightColor"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">highlightColor</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public var highlightColor:uint</code><p>
        The color used to highlight strings (RGBA).
        
        </p><p>The default value is <code>0xffff0000 (red)</code>.</p>
</div>
<a name="xOffset"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">xOffset</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public var xOffset:Number</code><p>
        The horizontal offset for highlights.
        
        </p><p>The default value is <code>0</code>.</p>
</div>
<a name="yOffset"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">yOffset</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public var yOffset:Number</code><p>
        The vertical offset for highlights.
        
        </p><p>The default value is <code>0</code>.</p>
</div>
<a name="constructorDetail"></a>
<div class="detailSectionHeader">Constructor detail</div>
<a name="Highlighter()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">Highlighter</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">constructor</td>
</tr>
</table>
<div class="detailBody">
<code>public function Highlighter(textField:TextField, color:uint = 0xffff0000, xOffset:Number = 0, yOffset:Number = 0)</code><p>
        Finds & highlights strings in a text field.
        
        </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">textField</span>:TextField</code> &mdash; The TextField containing the text to highlight
        </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">color</span>:uint</code> (default = <code>0xffff0000</code>)<code></code> &mdash; The color to make the highlight (RGBA).  Default is 0xffff0000 (solid red).
        </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">xOffset</span>:Number</code> (default = <code>0</code>)<code></code> &mdash; If necessary, the horizontal offset of the highlight.  Useful when the TextField has some padding applied to it.  Default is 0.
        </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">yOffset</span>:Number</code> (default = <code>0</code>)<code></code> &mdash; If necessary, the vertical offset of the highlight.  Useful when the TextField has some padding applied to it.  Default is 0.
        </td>
</tr>
</table>
</div>
<a name="methodDetail"></a>
<div class="detailSectionHeader">Method detail</div>
<a name="highlightNext()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">highlightNext</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td>
</tr>
</table>
<div class="detailBody">
<code>public function highlightNext(word:String, caseSensitive:Boolean = true):void</code><p>
        Highlights the first instance of a string after the cursor position.
        
        </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">word</span>:String</code> &mdash; The string to find and highlight.
        </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">caseSensitive</span>:Boolean</code> (default = <code>true</code>)<code></code></td>
</tr>
</table>
</div>
<a name="highlightPrevious()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">highlightPrevious</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function highlightPrevious(word:String, caseSensitive:Boolean = true):void</code><p>
        Highlights the first instance of a string before the cursor position.
        
        </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">word</span>:String</code> &mdash; The string to find and highlight.
        </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">caseSensitive</span>:Boolean</code> (default = <code>true</code>)<code></code></td>
</tr>
</table>
</div>
<a name="highlightWordInstances()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">highlightWordInstances</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function highlightWordInstances(word:String, caseSensitive:Boolean = true):void</code><p>
  Highlights all instances of a string.
  
  </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">word</span>:String</code> &mdash; The string to find and highlight.
  </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">caseSensitive</span>:Boolean</code> (default = <code>true</code>)<code></code></td>
</tr>
</table>
</div>
<a name="reset()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">reset</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function reset():void</code><p>
        Resets the Highlighter, clearing all visible highlights and emptying the array of character boundaries.
        </p></div>
<br>
<br>
<hr>
<br>
<p></p>
<center class="copyright"> 
</center>
</div>
</body>
</html>
<!-- -->
